Optimal. Leaf size=24 \[ \frac{a \tanh ^{-1}(\sin (c+d x))}{d}+\frac{b \tan (c+d x)}{d} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0260089, antiderivative size = 24, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 4, integrand size = 17, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.235, Rules used = {3787, 3770, 3767, 8} \[ \frac{a \tanh ^{-1}(\sin (c+d x))}{d}+\frac{b \tan (c+d x)}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3787
Rule 3770
Rule 3767
Rule 8
Rubi steps
\begin{align*} \int \sec (c+d x) (a+b \sec (c+d x)) \, dx &=a \int \sec (c+d x) \, dx+b \int \sec ^2(c+d x) \, dx\\ &=\frac{a \tanh ^{-1}(\sin (c+d x))}{d}-\frac{b \operatorname{Subst}(\int 1 \, dx,x,-\tan (c+d x))}{d}\\ &=\frac{a \tanh ^{-1}(\sin (c+d x))}{d}+\frac{b \tan (c+d x)}{d}\\ \end{align*}
Mathematica [A] time = 0.0122902, size = 24, normalized size = 1. \[ \frac{a \tanh ^{-1}(\sin (c+d x))}{d}+\frac{b \tan (c+d x)}{d} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.018, size = 32, normalized size = 1.3 \begin{align*}{\frac{a\ln \left ( \sec \left ( dx+c \right ) +\tan \left ( dx+c \right ) \right ) }{d}}+{\frac{b\tan \left ( dx+c \right ) }{d}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.06224, size = 39, normalized size = 1.62 \begin{align*} \frac{a \log \left (\sec \left (d x + c\right ) + \tan \left (d x + c\right )\right ) + b \tan \left (d x + c\right )}{d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 1.97673, size = 162, normalized size = 6.75 \begin{align*} \frac{a \cos \left (d x + c\right ) \log \left (\sin \left (d x + c\right ) + 1\right ) - a \cos \left (d x + c\right ) \log \left (-\sin \left (d x + c\right ) + 1\right ) + 2 \, b \sin \left (d x + c\right )}{2 \, d \cos \left (d x + c\right )} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 3.75222, size = 37, normalized size = 1.54 \begin{align*} \begin{cases} \frac{a \log{\left (\tan{\left (c + d x \right )} + \sec{\left (c + d x \right )} \right )} + b \tan{\left (c + d x \right )}}{d} & \text{for}\: d \neq 0 \\x \left (a + b \sec{\left (c \right )}\right ) \sec{\left (c \right )} & \text{otherwise} \end{cases} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.25528, size = 85, normalized size = 3.54 \begin{align*} \frac{a \log \left ({\left | \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) + 1 \right |}\right ) - a \log \left ({\left | \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right ) - 1 \right |}\right ) - \frac{2 \, b \tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )}{\tan \left (\frac{1}{2} \, d x + \frac{1}{2} \, c\right )^{2} - 1}}{d} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]